package com.aruba.provider.service.impl;

import com.aruba.api.DubboDeptService;
import com.aruba.bean.Dept;
import com.aruba.mapper.DeptMapper;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import org.apache.dubbo.config.annotation.DubboService;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

@DubboService
public class DubboDeptServiceImpl implements DubboDeptService {

    @Autowired
    private DeptMapper deptMapper;

    @Override
    public List<Dept> findAllDept() {
        Wrapper<Dept> queryWrapper = new QueryWrapper<>();

        return deptMapper.selectList(queryWrapper);
    }

}
